package com.fengyi.homefurnish.controller;

import com.fengyi.homefurnish.pojo.CouponsInfo;
import com.fengyi.homefurnish.service.CouponsInfoService;
import com.fengyi.homefurnish.utils.Pager;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/coupons")
public class CouponsInfoController {

    @Resource
    private CouponsInfoService couponsInfoService;

    @RequestMapping("/getAllCoupons")
    public Pager<CouponsInfo> getAllList(Integer offset, Integer limit, CouponsInfo couponsInfo){
        return couponsInfoService.getCouponsPager(offset,limit,couponsInfo);
    }

}
